<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
    <style>
        .gd{
            width: 200px;
            height: 100px;
            background-color: pink;
            /* transition: 要过渡的属性 花费时间 运动曲线 何时开始 */
            /* 谁做过渡给谁加 */
            /* transition: width .5s, height.5s; */
            transition: all .5s;
        }
        .gd:hover{
            width: 400px;
            height: 200px;
            background-color: skyblue;
        }

        .jd{
            width: 150px;
            height: 10px;
            margin-top: 100px;
            border: 1px solid red;
            border-radius: 5px;
        }
        .bar{
            width: 50%;
            height: 100%;
            background-color: red;
            transition: width 1s;
        }
        .jd:hover .bar{
            width: 100%;
        }
    </style>
</head>
<body>
    <div class="gd">过渡</div>
    <div class="jd">
        <div class="bar"></div>
    </div>
</body>
</html>